package com.addplus.townmall.server.api.mapper.town;

import com.addplus.townmall.server.api.model.town.OrderShipping;
import com.addplus.townmall.server.api.utils.BaseAddMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 * 商城订单配送表 Mapper 接口
 * </p>
 *
 * @author zhangjiehang
 * @since 2018-09-25
 */
public interface OrderShippingMapper extends BaseAddMapper<OrderShipping> {


    @Select("SELECT\n" +
            " id,\n" +
            " receipt_name,\n" +
            " receipt_mobile,\n" +
            " receipt_address,\n" +
            " receipt_full_address \n" +
            "FROM\n" +
            " order_shipping \n" +
            "WHERE\n" +
            " order_id = #{id} \n" +
            " AND is_delete = 0 \n")
    OrderShipping getOrderShippingByOrderId(@Param("id") Integer orderId);

}
